package org.webball.base.interfaces;

import java.io.Serializable;

import org.webball.base.abstracts.AbstractPlayer;

/**
 * Interface represents team in the game. It includes 6 players.
 * Also contains points and setpoints
 * @author Maciej Koch
 *
 */
public interface ITeam extends Serializable{

	/**
	 * 
	 * @return
	 * - points in set
	 */
	public int getPoints();
	
	/**
	 * 
	 * @return
	 * - setpoints
	 */
	public int getSetpoints();
	
	/**
	 * adds point to team, adds set point if necessary 
	 */
	public void addPoint();
	
	/**
	 * 
	 * @return true if is new set, false if not
	 */
	public boolean isNewSet();
	/**
	 * returns selected player
	 * @param i
	 * -which player select(0-5)
	 * @return
	 * - selected player
	 */
	public AbstractPlayer getPlayer(int i);
	/**
	 * Copies values from specified team.
	 * @param team
	 * - team, not <code>null</code>
	 */
	public void copy(ITeam team);
	/**
	 * returns all players
	 * @return
	 * all players in team
	 */
	public AbstractPlayer[] getAllPlayers();
}
